/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package tcloudclient.traySupport;

import java.awt.TrayIcon.MessageType;
import tcloudclient.watchService.WatchServiceChangeData;
import tcloudclient.watchService.WatchServiceEventInterface;

/**
 *
 * @author Tomas
 */
public class TraySupportWatchServiceObserver implements WatchServiceEventInterface{

    private TraySupport traySupport;

    public TraySupportWatchServiceObserver(TraySupport traySupport) {
        this.traySupport = traySupport;
    }    
    
    @Override
    public void event(WatchServiceChangeData data) { 
        traySupport.displayMessage("File system event!", data.getOperationType().toString() +": " + data.getFolder(), MessageType.INFO);
    }
    
}
